package com.base.third.mob

import com.dtflys.forest.annotation.Body
import com.dtflys.forest.annotation.Request
import org.springframework.stereotype.Service
import java.util.*

@Service
interface MobClient {
    @Request(
        url = "https://webapi.sms.mob.com/sms/verify",
        type = "POST",
    )
    fun verify(
        @Body("phone") phone: String,
        @Body("phone") code: String,
        @Body("appkey") appkey: String,
        @Body("zone") zone: String,
    ): Map<String, Any?>?

    @Request(
        url = "http://identify.verify.mob.com/auth/auth/sdkClientFreeLogin",
        type = "POST",
        contentType = "application/json",
    )
    fun sdkClientFreeLogin(
        @Body("opToken") opToken: String,
        @Body("operator") operator: String,
        @Body("token") token: String,
        @Body("appkey") appkey: String,
        @Body("timestamp") timestamp: Long,
        @Body("sign") sign: String,
    ): Map<String, Any?>?
}
